home *** CD-ROM | disk | FTP | other *** search
- //----------------------------------------------------------------------------
- // Moneycal.hpp - bcbdcc32 generated hdr (DO NOT EDIT) rev: 0
- // From: Moneycal.pas
- //----------------------------------------------------------------------------
- #ifndef MoneycalHPP
- #define MoneycalHPP
- //----------------------------------------------------------------------------
- #include <ExtCtrls.hpp>
- #include <StdCtrls.hpp>
- #include <Dialogs.hpp>
- #include <Forms.hpp>
- #include <Controls.hpp>
- #include <Graphics.hpp>
- #include <Classes.hpp>
- #include <Messages.hpp>
- #include <Windows.hpp>
- #include <SysUtils.hpp>
- #include <System.hpp>
- namespace Moneycal
- {
- //-- type declarations -------------------------------------------------------
- typedef SmallString<2> TDayStr;
-
- typedef SmallString<3> TMonthStr;
-
- typedef TDayStr TDayArray[14];
-
- typedef TMonthStr TMonthArray[12];
-
- class __declspec(delphiclass) TCalForm;
- class __declspec(pascalimplementation) TCalForm : public Forms::TForm
- {
- typedef Forms::TForm inherited;
-
- __published:
- void __fastcall FormCreate(System::TObject* Sender);
- void __fastcall FormShow(System::TObject* Sender);
- void __fastcall FormClose(System::TObject* Sender, Forms::TCloseAction &Action);
- void __fastcall FormMouseMove(System::TObject* Sender, Classes::TShiftState Shift, int X, int Y);
- void __fastcall FormMouseDown(System::TObject* Sender, Controls::TMouseButton Button, Classes::TShiftState
- Shift, int X, int Y);
- void __fastcall FormMouseUp(System::TObject* Sender, Controls::TMouseButton Button, Classes::TShiftState
- Shift, int X, int Y);
- void __fastcall FormPaint(System::TObject* Sender);
- void __fastcall FormKeyPress(System::TObject* Sender, char &Key);
- void __fastcall FormKeyDown(System::TObject* Sender, Word &Key, Classes::TShiftState Shift);
-
- private:
- int xoffset;
- int yoffset;
- TDayStr days[14];
- TMonthStr months[12];
- System::TDateTime seldate;
- System::TDateTime thedate;
- System::TDateTime initdate;
- Word startday;
- int frstday;
- int frstmonth;
- Word dx;
- Word dy;
- Word lblx1;
- Word lblx2;
- int xposin;
- int yposin;
- bool flgl;
- bool flgr;
- bool flgla;
- bool daymode;
- System::SmallString<12> labels;
- Graphics::TColor txtcolor;
- Graphics::TColor txtselcolor;
- Graphics::TColor txtinvcolor;
- Graphics::TColor txtwkndcolor;
- void __fastcall SetLabel(Word mo, Word ye);
- void __fastcall ChangeMonth(int dx);
- void __fastcall ChangeYear(int dx);
- Word __fastcall DaysInMonth(Word mo, Word ye);
- int __fastcall DateToWeek(Word da, Word mo, Word ye);
- void __fastcall PaintArrowLeft(void);
- void __fastcall PaintArrowRight(void);
- void __fastcall PaintLabel(void);
- void __fastcall PaintProc(void);
- void __fastcall ToggleDayMode(void);
-
- public:
- __fastcall virtual TCalForm(Classes::TComponent* AOwner);
- void __fastcall SetDate(Word da, Word mo, Word ye);
- void __fastcall GetDate(Word &da, Word &mo, Word &ye);
- void __fastcall SetStartDay(Word aday);
- void __fastcall SetColors(Graphics::TColor textcolor, Graphics::TColor selectcolor, Graphics::TColor
- inverscolor, Graphics::TColor weekendcolor);
- void __fastcall SetNameofDays(const TDayStr * d);
- void __fastcall SetNameofMonths(const TMonthStr * m);
- void __fastcall SetWeeks(bool onoff);
- void __fastcall SetStarts(int d, int m);
-
- protected:
- virtual void __fastcall CreateParams(Controls::TCreateParams &Params);
- public:
- /* TForm.CreateNew */ __fastcall TCalForm(Classes::TComponent* AOwner, int Dummy) : Forms::TForm(AOwner
- , Dummy) { }
- /* TForm.Destroy */ __fastcall virtual ~TCalForm(void) { }
-
- public:
- /* TWinControl.CreateParented */ __fastcall TCalForm(HWND ParentWindow) : Forms::TForm(ParentWindow
- ) { }
-
- };
-
- //-- var, const, procedure ---------------------------------------------------
- extern Word adaysinmonth[13];
- extern System::SmallString<5> monames[12];
- #define selstr "Select month"
- #define labelx (Byte)(30)
- #define labelw (Byte)(65)
- extern TCalForm* CalForm;
- //-- template instantiations -------------------------------------------------
- template class SmallString<5> ;
- template class SmallString<12> ;
- template class SmallString<3> ;
- template class SmallString<2> ;
-
- } /* namespace Moneycal */
- #if !defined(NO_IMPLICIT_NAMESPACE_USE)
- using namespace Moneycal;
- #endif
- //-- end unit ----------------------------------------------------------------
- #endif // Moneycal
-